home *** CD-ROM | disk | FTP | other *** search
/ Mac100% 1998 November / MAC100-1998-11.ISO.7z / MAC100-1998-11.ISO / オンラインソフト定点観測 / デモ / DesignWorks 4.0.1 PPC Demo.sea / DesignWorks 4.0.1 Demo PowerMac / Design Kits / Generic Spice / Scripts / SPICE Info Script < prev    next >
Text File  |  1997-05-27  |  847b  |  34 lines

  1. {
  2.   Copyright 1997 by Capilano Computing Systems Ltd.
  3.  
  4.   Script to prompt for a Spice code for the selected devices.
  5.   First, turn off report generation.
  6. }
  7. $REPORTOFF
  8. $PROGRESS $OFF
  9. {
  10.   Find selected devices and pretend they're sorted so we can merge all values
  11.   in the Spice field into one.
  12. }
  13. $FIND $DEVICES $SELECTED
  14. $SORT $DEVICES $RAW
  15. $COMBDEVSON
  16. {
  17.   If nothing's selected, quit
  18. }
  19. $IF($EQ($DEVCOUNT, 0))
  20. $ALERT1(No devices are selected!)
  21. $ABORT
  22. $END
  23. {
  24.   If we have more than one value in the selected devices, use an empty initial value
  25. }
  26. $DEVICES$SETVAR(_SpiceVal, $IF($EQ($COUNTVALUES(&Spice), 1))&Spice$END)
  27. {
  28.   Put up a prompt box.  Note that we abort if the user presses Cancel
  29. }
  30. $SETVAR(_SpiceVal, $PROMPT2(Enter SPICE parameters for selected devices, &_SpiceVal))
  31. {
  32.   Set the Spice in all devices.
  33. }
  34. $DEVICES$SETATTR(Spice, &_SpiceVal)